<template>
	<view>
		<mumu-one-code @success="handlerSuccess" definition continue :readers="readers"></mumu-one-code>
		<view class="record">
			<view class="list" v-for="item in codes">{{ item }}</view>
		</view>
	</view>
</template>

<script>
import MumuOneCode from '@/uni_modules/mumu-oneCode/components/mumu-oneCode/mumu-oneCode.vue'

export default {
	components: { MumuOneCode },
	data() {
		return {
			codes: [],
			readers: ['ean_reader']
		}
	},
	onLoad() {},
	methods: {
		handlerSuccess(code) {
			console.log(code)
			this.codes.push(code)
			/* 	uni.showModal({
					content: code
				}) */
		}
	}
}
</script>

<style lang="scss" scoped>
.record {
	position: fixed;
	top: 0;
	left: 0;
	width: 50%;
	height: 400rpx;
	overflow: auto;
	background-color: rgba(000, 000, 000, 0.5);
	z-index: 9999;
	color: #fff;
	font-size: 12px;
}
</style>
